package net.jxvtc.ioc.di;

public class UserService {
    private UserDao userDao;
    private String name;
    private int age;
    public UserService(UserDao userDao){
        this.userDao=userDao;
    }
    public UserService(int age , String name ,UserDao userDao) {
        this.userDao = userDao;
        this.age = age;
        this.name = name;
    }
    public void save(){
        this.userDao.save();
    }
    public void display(){
        System.out.println(userDao+"|"+name+"|"+age);
    }
}
